//
//  HYQTestCollectionViewCell.m
//  HYQImagePickerController_Example
//
//  Created by zhuxingjian on 2018/8/27.
//  Copyright © 2018年 zxj1989. All rights reserved.
//

#import "HYQTestCollectionViewCell.h"

@implementation HYQTestCollectionViewCell

- (instancetype)initWithFrame:(CGRect)frame
{
    if (self = [super initWithFrame:frame]) {
        
        _imageView = [UIImageView new];
        _imageView.contentMode = UIViewContentModeScaleAspectFill;
        _imageView.clipsToBounds = YES;
        [self.contentView addSubview:_imageView];
        
        _delButton = [UIButton buttonWithType:UIButtonTypeCustom];
        _delButton.titleLabel.font = [UIFont systemFontOfSize:12];
        [_delButton setTitle:@"删除" forState:UIControlStateNormal];
        [_delButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
        [_delButton setBackgroundColor:[UIColor redColor]];
        [self.contentView addSubview:_delButton];
        
        _imageView.frame = self.bounds;
        _delButton.frame = CGRectMake(CGRectGetWidth(self.frame) - 40, 0, 40, 20);
    }
    return self;
}

@end
